import axios from 'axios';
import { ref } from 'vue';

const getSingle = (id) => {
    const singleData = ref({});
    const load = async () => {
        const { data } = await axios.get('http://localhost:3000/listData/'+id);
        console.log(data);
        singleData.value = data;
    }

    load();
    return {singleData}
}

export default  getSingle